package com.zodiac.app.szse.sse.classification;

import com.zodiac.app.szse.sse.SseClient;
import com.zodiac.app.szse.sse.classification.dto.SseIndustryClassificationRequest;
import com.zodiac.app.szse.sse.classification.dto.SseIndustryClassificationResponse;

/**
 * 上交所-上市公司分类查询
 */
public class SseClassificationApi {

    private static final String INDUSTRY_CLASSIFICATION_QUERY_URL = "http://query.sse.com.cn/security/stock/queryIndustryIndex.do";

    /**
     * 行业分类查询
     *
     * @param request
     * @return
     */
    public SseIndustryClassificationResponse industryClassificationQuery(SseIndustryClassificationRequest request) {
        return SseClient.create(INDUSTRY_CLASSIFICATION_QUERY_URL).execute(request, SseIndustryClassificationResponse.class);
    }

}
